{extend name="public/base" /} {block name="body"}
<div class="content-tabs">
	<ol class="breadcrumb">
		<li>
			<a href="{:url('index/index')}"><i class="fa fa-home"></i></a>
		</li>
		<li><strong>角色列表</strong></li>
	</ol>
</div>
<div class="ibox float-e-margins">
	<div class="ibox-title">
		<h5>角色列表</h5>
	</div>
	<div class="ibox-content">
		<div class="row">
			<div class="col-sm-12">
				<div class="col-sm-2">
					<div class="input-group">
						<a href="{:url('add')}" class="btn btn-primary btn-outline">添加角色</a>
					</div>
				</div>
			</div>
		</div>
		<div class="hr-line-dashed"></div>
		<div class="example-wrap">
			<div class="example">
				<form method="post" action="{:url('index')}">
					<table class="table table-bordered table-hover">
						<thead>
							<tr class="long-th">
								<th width="50">ID</th>
								<th>名称</th>
								<th>状态</th>
								<th>添加时间</th>
								<th width="100">排序</th>
								<th>操作</th>
							</tr>
						</thead>
						<tbody>
							{foreach name="auth_group_list" item="vo"}
							<tr>
								<td class="text-center">{$vo.id}</td>
								<td>{$vo.title}</td>
								<td class="text-center">
									{if condition="$vo.status eq 1"}
									<a href="javascript:;" onclick="rule_state({$vo.id});">
										<div id="zt{$vo.id}"><span class="label label-info">正常</span></div>
									</a>
									{else/}
									<a href="javascript:;" onclick="rule_state({$vo.id});">
										<div id="zt{$vo.id}"><span class="label label-danger">禁用</span></div>
									</a>
									{/if}
								</td>
								<td class="text-center">{$vo.add_time}</td>
								<td class="text-center">{$vo.sort}</td>
								<td class="text-center">
									<a href="{:url('auth',['id'=>$vo.id])}" class="btn btn-success bnt-sm">
										<i class="fa fa-key"></i> 权限分配</a>&nbsp;&nbsp;
									<a href="{:url('update',['id'=>$vo.id])}" class="btn btn-primary bnt-sm">
										<i class="fa fa-paste"></i> 编辑</a>&nbsp;&nbsp;
									<a href="{:url('delete',['id'=>$vo.id])}" class="btn btn-danger bnt-sm ajax-delete">
										<i class="fa fa-trash-o"></i> 删除</a>
								</td>
							</tr>
							{/foreach}
						</tbody>
					</table>
				</form>
				{$auth_group_list->render()}
			</div>
		</div>
	</div>
</div>
{/block} {block name="script"}
<script>
</script>
{/block}